package top.buyibuyi.course.dao.admin;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Service;
import top.buyibuyi.course.pojo.Admin;
import top.buyibuyi.course.pojo.Semester;

import java.util.List;

@Mapper
public interface SelectSemesterDao {

    @Select("select * from semester where id limit #{startPage},#{limit}")
    List<Semester> selectSemester(@Param("startPage") int startPage, @Param("limit") int limit);


    @Select("select count(*) as 'totalpage' from semester")
    int selectCount();

    @Select("select * from semester where id = #{id}")
    Semester selectSemesterById(int id);
}
